﻿<UserControl x:Class="GamePlugin.Controls.AuctionControl"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="711" d:DesignWidth="755" DataContextChanged="UserControl_DataContextChanged">
    <Grid Width="754" Height="708">
        <ListBox Height="406" HorizontalAlignment="Left" Margin="454,23,0,0" Name="AuctionItemListBox" VerticalAlignment="Top" Width="288" 
                ItemsSource="{Binding Children}" SelectionChanged="AuctionItemListBox_SelectionChanged">
            <ListBox.ItemContainerStyle>
                <!-- This Style binds a TreeViewItem to a TreeItem. -->
                <Style TargetType="{x:Type ListBoxItem}">
                    <Style.Triggers>
                        <Trigger Property="IsSelected" Value="True">
                            <Setter Property="FontWeight" Value="Bold" />
                        </Trigger>
                    </Style.Triggers>
                </Style>
            </ListBox.ItemContainerStyle>
            <ListBox.ItemTemplate>
                <DataTemplate>
                    <TextBlock Text="{Binding Path=DisplayName}"/>
                </DataTemplate>
            </ListBox.ItemTemplate>
        </ListBox>
        
        <Border BorderBrush="Silver" BorderThickness="1" Height="680" HorizontalAlignment="Left" Margin="12,25,0,0" Name="border1" VerticalAlignment="Top" Width="428">
            <Image Height="646" HorizontalAlignment="Left" Margin="0,0,0,0" Name="image1" Stretch="Fill" VerticalAlignment="Top" Width="424" 
               Source ="{Binding ImageSource}"/>
        </Border>
        <Label Content="前缀名称" Height="28" HorizontalAlignment="Left" Margin="468,450,0,0" Name="label1" VerticalAlignment="Top" Width="60" />
        <Label Content="竞拍价格" Height="28" HorizontalAlignment="Left" Margin="468,479,0,0" Name="label2" VerticalAlignment="Top" Width="60" />
        <Label Content="终止时间" Height="28" HorizontalAlignment="Left" Margin="468,513,0,0" Name="label3" VerticalAlignment="Top" Width="80" />
        <Button Content="修改" Height="23" HorizontalAlignment="Left" Margin="468,571,0,0" Name="ModifyButton" VerticalAlignment="Top" Width="75" />
        <TextBox Height="23" Text="{Binding NamePrefix}"  HorizontalAlignment="Right" Margin="0,450,24,0" Name="textBox1" VerticalAlignment="Top" Width="180" />
        <Button Content="排序" Height="23" HorizontalAlignment="Left" Margin="468,611,0,0" Name="SortButton" VerticalAlignment="Top" Width="75" />
        <Button Content="存储" Height="23" HorizontalAlignment="Left" Margin="468,649,0,0" Name="SaveButton" VerticalAlignment="Top" Width="75" Click="SaveButton_Click" />
        <Button Content="读入" Height="23" HorizontalAlignment="Left" Margin="582,649,0,0" Name="LoadButton" VerticalAlignment="Top" Width="75" Click="LoadButton_Click" />
        <CheckBox Content="是否精确时间"  IsChecked="{Binding IsExactDeadline}" Height="20" HorizontalAlignment="Left" Margin="641,513,0,0" Name="checkBox1" VerticalAlignment="Top" />
        <xctk:IntegerUpDown Value ="{Binding Path=AuctionPrice}" Increment="1" Margin="550,482,24,201" Maximum="2000000000" Minimum="0" />
    </Grid>
</UserControl>
